package com.tuanzi.loan.web.lazy.xhh.settlementsystem;

import com.tuanzi.loan.business.service.xhh.settlementsystem.XhhSettlementBillService;
import com.tuanzi.loan.core.lazy.BaseLazyDataModel;
import com.tuanzi.loan.core.util.SpringContextHolder;
import com.tuanzi.loan.core.vo.PageSearcher;
import com.tuanzi.loan.vo.request.xhh.settlementsystem.XhhSettlementBillRequest;
import com.tuanzi.loan.vo.response.xhh.settlementsystem.XhhSettlementBillResponse;
import org.springframework.data.domain.Page;

/**
 * @author caiwanlin
 * @create 2018-01-25 20:17
 */
public class XhhSettlementBillLazyDataModel extends BaseLazyDataModel<XhhSettlementBillRequest, XhhSettlementBillResponse> {
    private XhhSettlementBillService xhhSettlementBillService = SpringContextHolder.getBean(XhhSettlementBillService.class);

    public XhhSettlementBillLazyDataModel(XhhSettlementBillRequest settlementBillRequest) {
        super(settlementBillRequest);
    }
    @Override
    protected Page<XhhSettlementBillResponse> doLoad(PageSearcher<XhhSettlementBillRequest> pageSearcher) {
        return xhhSettlementBillService.list(pageSearcher);
    }
}
